Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Communities: Show relevant tokens #18636

Merged
merged 3 commits into from
Feb 8, 2024
Merged

Conversation

ilmotta
Copy link
Contributor

@ilmotta ilmotta commented Jan 26, 2024

Fixes #18126

Summary

Show relevant tokens in account selection step. Related status-go PR status-im/status-go#4631.

Things that surely can be done in follow-ups:

  • Improve the preview screen of quo.wallet.account-permissions to show collectibles in the token details section.
  • Show the correct collectible's image. I hardcoded a dummy one for now.

Things that could become follow-up/improvement PRs:

  • There's no loading indicator that relevant tokens are being fetched, and sometimes fetching them takes more than a few seconds.
  • As @yqrashawn mentioned recently, pulling balances all the time is not really ideal, and we do that every time the user opens the addresses for selection modal.

Review notes

  • Balances are fetched on the account selection screen. Assuming most users won't care about selecting addresses, this eliminates unnecessary calls to get balances, at the expense of refetching them every time the component is mounted. I think for now this is acceptable.
  • Relevant tokens is a terminology used in Figma, but more specifically, it means "balances for all assets that have at least one Token Criteria associated, and for a given address". Or, as I tried to give it a more distinct name, "permissioned balances".

Areas that may be impacted

None because all affected code is behind a disabled feature flag.

Screenshot of the functionality

Steps to test

  1. Enable flag status-im.config/community-accounts-selection-enabled?
  2. Until issue Adding admin permissions / minting Owner token makes the community token gated for any user #18502 is solved, and to test this PR with minted tokens and collectibles, you will need to apply a workaround to forcefully go to the new join community flows.
Workaround
modified   src/status_im/contexts/communities/overview/view.cljs
@@ -180,7 +180,6 @@
     [:<>
      (when-not (or joined pending? invite-only? unknown-access?)
        (if (seq token-permissions)
-         [token-gates community]
          [quo/button
           {:on-press
            (if config/community-accounts-selection-enabled?
@@ -190,7 +189,8 @@
            :accessibility-label :show-request-to-join-screen-button
            :customization-color color
            :icon-left :i/communities}
-          (i18n/label :t/request-to-join-community)]))
+          (i18n/label :t/request-to-join-community)]
+         [token-gates community]))

status: ready

@ilmotta ilmotta added feature feature requests community labels Jan 26, 2024
@ilmotta ilmotta self-assigned this Jan 26, 2024
@@ -24,7 +24,7 @@
[:address [:maybe :string]]
[:emoji [:maybe :string]]
[:customization-color [:maybe [:or :string :keyword]]]]]
[:token-details {:optional true} [:maybe [:vector required-tokens/?schema]]]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: :vector is rarely the schema we want to use because it will fail when lazy sequences are passed.

[utils.re-frame :as rf]))

(defn get-permissioned-balances
[{[event-id _] :original-event} [community-id]]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: this is a nice way to grab the current event ID. Often the case when we want to log a descriptive error.

@status-im-auto
Copy link
Member

status-im-auto commented Jan 26, 2024

Jenkins Builds

Click to see older builds (27)
Commit #️⃣ Finished (UTC) Duration Platform Result
c364ba7 #1 2024-01-26 11:08:23 ~3 min tests 📄log
✔️ c364ba7 #1 2024-01-26 11:12:25 ~7 min ios 📱ipa 📲
✔️ c364ba7 #1 2024-01-26 11:12:57 ~7 min android-e2e 🤖apk 📲
✔️ c364ba7 #1 2024-01-26 11:13:19 ~8 min android 🤖apk 📲
20f10dd #2 2024-01-26 11:37:27 ~2 min tests 📄log
✔️ 20f10dd #2 2024-01-26 11:40:57 ~5 min ios 📱ipa 📲
✔️ 20f10dd #2 2024-01-26 11:43:10 ~7 min android-e2e 🤖apk 📲
✔️ 20f10dd #2 2024-01-26 11:44:11 ~8 min android 🤖apk 📲
✔️ 59f1ab8 #3 2024-01-26 12:39:57 ~5 min ios 📱ipa 📲
✔️ 59f1ab8 #3 2024-01-26 12:41:58 ~7 min android-e2e 🤖apk 📲
✔️ 59f1ab8 #3 2024-01-26 12:42:05 ~7 min android 🤖apk 📲
456e8ef #4 2024-01-26 15:08:25 ~2 min tests 📄log
✔️ 456e8ef #4 2024-01-26 15:12:17 ~6 min ios 📱ipa 📲
✔️ 456e8ef #4 2024-01-26 15:13:56 ~8 min android 🤖apk 📲
✔️ 456e8ef #4 2024-01-26 15:16:22 ~10 min android-e2e 🤖apk 📲
39ae4e1 #5 2024-01-30 10:50:15 ~6 min tests 📄log
✔️ 39ae4e1 #5 2024-01-30 10:51:02 ~6 min ios 📱ipa 📲
✔️ 39ae4e1 #5 2024-01-30 10:52:16 ~8 min android 🤖apk 📲
✔️ 39ae4e1 #5 2024-01-30 10:52:27 ~8 min android-e2e 🤖apk 📲
✔️ df9f5e0 #6 2024-01-30 11:15:47 ~5 min tests 📄log
✔️ df9f5e0 #6 2024-01-30 11:15:59 ~6 min ios 📱ipa 📲
✔️ df9f5e0 #6 2024-01-30 11:17:16 ~7 min android-e2e 🤖apk 📲
✔️ df9f5e0 #6 2024-01-30 11:19:34 ~9 min android 🤖apk 📲
✔️ 3ead902 #7 2024-01-30 19:01:43 ~5 min tests 📄log
✔️ 3ead902 #7 2024-01-30 19:02:14 ~5 min ios 📱ipa 📲
✔️ 3ead902 #7 2024-01-30 19:03:18 ~6 min android 🤖apk 📲
✔️ 3ead902 #7 2024-01-30 19:04:14 ~7 min android-e2e 🤖apk 📲
Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ 5466e1f #9 2024-02-06 11:25:16 ~7 min tests 📄log
✔️ 5466e1f #9 2024-02-06 11:25:24 ~8 min ios 📱ipa 📲
✔️ 5466e1f #9 2024-02-06 11:25:31 ~8 min android-e2e 🤖apk 📲
✔️ 5466e1f #9 2024-02-06 11:26:27 ~9 min android 🤖apk 📲
✔️ dae24ea #10 2024-02-08 12:42:27 ~7 min tests 📄log
✔️ dae24ea #10 2024-02-08 12:42:37 ~7 min android-e2e 🤖apk 📲
✔️ dae24ea #10 2024-02-08 12:45:15 ~10 min android 🤖apk 📲
✔️ dae24ea #10 2024-02-08 12:45:57 ~10 min ios 📱ipa 📲

[:decimals int?]
[:amount string?]]]])

(schema/=> get-permissioned-balances-success
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yqrashawn There's a strong pattern in the way we write schemas for event handlers. We could go just a small step further to help alleviate the verbosity for 95% of our use cases. Something to be discussed, but sharing here to give some visibility of the idea.

In the example below, the first argument to :=> would be the event args directly, the rest is almost always the same, and when they aren't, the dev would be able to use schema/=> instead.

(schema/event=> get-permissioned-balances-success
  [:=>
   [:catn
    [:community-id string?]
    [:response ?permissioned-balances-response]]
   [:map {:closed true}
    [:db map?]]])

cc @clauxx

Copy link
Member

@clauxx clauxx Jan 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be great to get rid of the boilerplate, I agree. Not as verbose as events, but for quo components we could do the same and just pass a prop map schema.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we definitely need this.

I'm thinking about something like ring's middleware and wrap- functions
Or functions start with assoc- or walk- to transform schema.
These kinds of functions are easier to document, understand and maintain.

I checked Malli's schema transformation the other day. There are these get assoc functions implemented for [LensSchema](https://github.com/metosin/malli/blob/1d6efc23fef01ab333f872b357760de61eac0a21/src/malli/util.cljc#L303), but I didn't manage to figure out what's lens schema. Maybe something like specter?

If that's what we are using. It would be great.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm thinking about something like ring's middleware and wrap- functions

@yqrashawn Last week I wrote a malli transformer similar to malli.util/optional-keys just to get the feeling of it and to solve one pain point I have in status-mobile. No PR, just experimentation. Transformers are interesting also because they're just functions and we can compose them, which if I understood you correctly is something you would like to have.

OTOH, transformers may be a bazooka to solve a simple problem of just eliminating the most essential boilerplate to define event handler schemas. For that, we just need a vanilla Clojure function and no need to use specific Malli APIs.

but I didn't manage to figure out what's lens schema.

I only know what lenses are and why they exist in functional languages, but I have zero knowledge about this part of Malli. Looks like something to be explored!

Maybe something like specter?

I've never used specter outside playground stuff, but it's surely one of a kind Clojure library. A bit too alien if you ask me.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OTOH, transformers may be a bazooka to solve a simple problem of just eliminating the most essential boilerplate to define event handler schemas. For that, we just need a vanilla Clojure function and no need to use specific Malli APIs.

Totally agree

Comment on lines 25 to 27
[:fx [:vector {:min 1 :max 1} :schema.common/rpc-call]]]])
[:fx
[:tuple
[:tuple [:= :json-rpc/call] :schema.common/rpc-call]]]]])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we be rigid about the returned effects map schema? From instrumenting events, I see most value from the arguments schema and by instrumenting the args from :json-rpc/call (or any other event/effect), we wouldn't need to check the args everywhere it's used. WDYT?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point. There's a balance to strike. We have some events checking only that :fx is a map. Here I wanted to make sure it's nothing more than a tuple of tuples to experiment a little bit. I don't think this should be done all the time.

But I think the more we spec events, the more we should think about coming up with a schema representing re-frame's effects map. Our guidelines recommend using only :db and :fx in the returned map, so we could reinforce this idea more generally.

This generality won't be able to check something like I did OTOH, it will be more "open", but I think that's okay.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, enforcing the guideline through the schema here would be more useful than the specific events and effects that are returned 👍. Can we instrument the :json-rpc/call effect instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh definitely, we should instrument all highly used utilities/functions IMO. Those are the ones where it pays off to have schemas.

We had an agreement in the beginning to not spec non-component stuff, but time has passed and the team seems to be okay with Malli and a few are even enjoying. I think it's a good time to start already.

Copy link
Contributor Author

@ilmotta ilmotta Jan 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we instrument the :json-rpc/call effect instead?

We can instrument the function call, but in re-frame, events just return data, so we need to instrument the event handlers themselves because the status-im.common.json-rpc.events/call is never called directly.

@ilmotta ilmotta force-pushed the ilmotta.18126/relevant-tokens branch 2 times, most recently from df9f5e0 to 3ead902 Compare January 30, 2024 18:56
@Samyoul Samyoul added the community-account-selection https://www.notion.so/Ledger-Drops-b0df9c843f904bb380133375bae3faa7 label Feb 2, 2024
@ilmotta ilmotta force-pushed the ilmotta.18126/relevant-tokens branch 2 times, most recently from 5486008 to 5466e1f Compare February 6, 2024 11:17

(= type constants/community-token-type-erc721)
(assoc :collectible-name name
:collectible-img-src (resources/get-mock-image :collectible))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI: I'll create a follow-up issue to use the real collectible image. It just didn't seem important for this PR since there's a bunch of things going on in the status-go side.

Copy link
Contributor

@ajayesivan ajayesivan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Nice Work!

Use with-precision to show prettier amounts (workaround)

For reference, see status-im/status-desktop#8640
@ilmotta ilmotta force-pushed the ilmotta.18126/relevant-tokens branch from 5466e1f to dae24ea Compare February 8, 2024 12:34
@status-im-auto
Copy link
Member

19% of end-end tests have passed

Total executed tests: 48
Failed tests: 38
Expected to fail tests: 1
Passed tests: 9
IDs of failed tests: 703391,702732,704613,702948,702894,702851,702809,702782,702730,702841,703629,702838,702957,702859,703202,702745,703194,702733,702786,703495,703086,702807,702840,703297,702845,702855,702783,702731,702844,702947,702775,702839,702936,704615,702813,702808,702958,702843 
IDs of expected to fail tests: 703503 

Failed tests (38)

Click to expand
  • Rerun failed tests

  • Class TestCommunityMultipleDeviceMerged:

    1. test_community_contact_block_unblock_offline, id: 702894
    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    2. test_community_unread_messages_badge, id: 702841

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    3. test_community_message_send_check_timestamps_sender_username, id: 702838

    Device 2: Find Button by xpath: //*[@content-desc='password-input']/../following-sibling::*//*[@text='Join Community']
    Device 2: Tap on found: Button

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    4. test_community_one_image_send_reply, id: 702859

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    5. test_community_several_images_send_reply, id: 703194

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    6. test_community_mark_all_messages_as_read, id: 703086

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    7. test_community_emoji_send_copy_paste_reply, id: 702840

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    8. test_community_links_with_previews_github_youtube_twitter_gif_send_enable, id: 702844

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    9. test_community_message_delete, id: 702839

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    10. test_community_edit_delete_message_when_offline, id: 704615

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    11. test_community_message_edit, id: 702843

    Test setup failed: critical/chats/test_public_chat_browsing.py:322: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:442: in join_community
        self.community_status_joined.wait_for_visibility_of_element(60)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by accessibility id:`status-tag-positive` is not found on the screen after wait_for_visibility_of_element
    



    Class TestCommunityMultipleDeviceMergedTwo:

    1. test_community_hashtag_links_to_community_channels, id: 702948

    Test setup failed: critical/chats/test_public_chat_browsing.py:837: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:436: in join_community
        self.join_button.wait_and_click(120)
    ../views/base_element.py:96: in wait_and_click
        self.wait_for_visibility_of_element(sec)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Button by accessibility id:`show-request-to-join-screen-button` is not found on the screen after wait_for_visibility_of_element
    



    2. test_community_markdown_support, id: 702809

    Test setup failed: critical/chats/test_public_chat_browsing.py:837: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:436: in join_community
        self.join_button.wait_and_click(120)
    ../views/base_element.py:96: in wait_and_click
        self.wait_for_visibility_of_element(sec)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Button by accessibility id:`show-request-to-join-screen-button` is not found on the screen after wait_for_visibility_of_element
    



    3. test_community_join_when_node_owner_offline, id: 703629

    Test setup failed: critical/chats/test_public_chat_browsing.py:837: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:436: in join_community
        self.join_button.wait_and_click(120)
    ../views/base_element.py:96: in wait_and_click
        self.wait_for_visibility_of_element(sec)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Button by accessibility id:`show-request-to-join-screen-button` is not found on the screen after wait_for_visibility_of_element
    



    4. test_community_mentions_push_notification, id: 702786

    Device 2: Find Text by xpath: //android.view.ViewGroup[@content-desc='chat-item']//android.widget.TextView[contains(@text,'https://status.app/c/')]
    Device 2: Wait for element Button for max 120s and click when it is available

    Test setup failed: critical/chats/test_public_chat_browsing.py:837: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:436: in join_community
        self.join_button.wait_and_click(120)
    ../views/base_element.py:96: in wait_and_click
        self.wait_for_visibility_of_element(sec)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Button by accessibility id:`show-request-to-join-screen-button` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    5. test_community_leave, id: 702845

    Test setup failed: critical/chats/test_public_chat_browsing.py:837: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:436: in join_community
        self.join_button.wait_and_click(120)
    ../views/base_element.py:96: in wait_and_click
        self.wait_for_visibility_of_element(sec)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Button by accessibility id:`show-request-to-join-screen-button` is not found on the screen after wait_for_visibility_of_element
    



    Class TestOneToOneChatMultipleSharedDevicesNewUiTwo:

    1. test_1_1_chat_is_shown_message_sent_delivered_from_offline, id: 702783

    Device 2: Find Text by xpath: //*[starts-with(@text,'test message')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']//*[@content-desc='message-status']/android.widget.TextView
    Device 2: Text is Delivered

    critical/chats/test_1_1_public_chats.py:612: in test_1_1_chat_is_shown_message_sent_delivered_from_offline
        self.errors.verify_no_errors()
    base_test_case.py:191: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Message was not delivered after resending from offline
    



    Device sessions

    Class TestOneToOneChatMultipleSharedDevicesNewUi:

    1. test_1_1_chat_send_image_save_and_share, id: 703391

    Device 2: Looking for a message by text: test image
    Device 2: Looking for a message by text: test image

    critical/chats/test_1_1_public_chats.py:411: in test_1_1_chat_send_image_save_and_share
        self.chat_2.chat_element_by_text(image_description).wait_for_visibility_of_element(30)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: ChatElementByText by xpath:`//*[starts-with(@text,'test image')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    2. test_1_1_chat_emoji_send_reply_and_open_link, id: 702782

    Device 1: Long press on BaseElement until expected element is shown
    Device 1: Find Button by xpath: //*[@text="Reply"]

    critical/chats/test_1_1_public_chats.py:117: in test_1_1_chat_emoji_send_reply_and_open_link
        self.chat_1.quote_message(emoji_unicode)
    ../views/chat_view.py:1071: in quote_message
        self.reply_message_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by xpath: `//*[@text="Reply"]` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    3. test_1_1_chat_message_reaction, id: 702730

    Device 2: Wait for text element EmojisNumber to be equal to 1
    Device 2: Find EmojisNumber by xpath: //*[starts-with(@text,'Message sender')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']/../..//*[@content-desc='emoji-reaction-2']/android.widget.TextView[2]

    critical/chats/test_1_1_public_chats.py:64: in test_1_1_chat_message_reaction
        message_receiver.emojis_below_message(emoji="thumbs-up").wait_for_element_text(1, 90)
    ../views/base_element.py:173: in wait_for_element_text
        element_text = self.find_element().text.strip()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 2: EmojisNumber by xpath: `//*[starts-with(@text,'Message sender')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']/../..//*[@content-desc='emoji-reaction-2']/android.widget.TextView[2]` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    4. test_1_1_chat_non_latin_messages_stack_update_profile_photo, id: 702745

    Device 1: Tap on found: SendMessageButton
    Device 2: Looking for a message by text: profile_photo

    critical/chats/test_1_1_public_chats.py:306: in test_1_1_chat_non_latin_messages_stack_update_profile_photo
        self.chat_2.chat_element_by_text(message).wait_for_visibility_of_element(30)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: ChatElementByText by xpath:`//*[starts-with(@text,'profile_photo')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    5. test_1_1_chat_text_message_delete_push_disappear, id: 702733

    Device 2: Find Text by xpath: //*[starts-with(@text,'smth I should edit')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']
    Device 2: Tap on found: Text

    critical/chats/test_1_1_public_chats.py:470: in test_1_1_chat_text_message_delete_push_disappear
        self.chat_2.chat_element_by_text(message_after_edit_1_1).wait_for_status_to_be("Delivered")
    ../views/chat_view.py:243: in wait_for_status_to_be
        raise TimeoutException("Message status was not changed to %s, it's %s" % (expected_status, current_status))
     Message status was not changed to Delivered, it's Sending
    



    Device sessions

    6. test_1_1_chat_edit_message, id: 702855

    Device 2: Find Text by xpath: //*[starts-with(@text,'Message before edit 1-1')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']
    Device 2: Tap on found: Text

    critical/chats/test_1_1_public_chats.py:381: in test_1_1_chat_edit_message
        self.chat_2.chat_element_by_text(message_before_edit_1_1).wait_for_status_to_be("Delivered")
    ../views/chat_view.py:243: in wait_for_status_to_be
        raise TimeoutException("Message status was not changed to %s, it's %s" % (expected_status, current_status))
     Message status was not changed to Delivered, it's Sending
    



    Device sessions

    7. test_1_1_chat_pin_messages, id: 702731

    Device 1: Waiting for message to be sent for 30 sec
    Device 1: Find Text by xpath: //*[starts-with(@text,'Message 1')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']

    critical/chats/test_1_1_public_chats.py:186: in test_1_1_chat_pin_messages
        self.chat_1.chat_element_by_text(self.message_1).wait_for_status_to_be("Delivered")
    ../views/chat_view.py:239: in wait_for_status_to_be
        current_status = self.status
    ../views/chat_view.py:211: in status
        Text(self.driver, xpath=self.locator).click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Text by xpath: `//*[starts-with(@text,'Message 1')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    8. test_1_1_chat_push_emoji, id: 702813

    # STEP: Device 1 checks PN with emoji
    Device 1: Click system back button

    critical/chats/test_1_1_public_chats.py:355: in test_1_1_chat_push_emoji
        self.device_1.driver.fail("Push notification with emoji was not received")
    base_test_case.py:179: in fail
        pytest.fail('Device %s: %s' % (self.number, text))
     Device 1: Push notification with emoji was not received
    



    Device sessions

    Class TestActivityCenterContactRequestMultipleDevicePR:

    1. test_activity_center_contact_request_accept_swipe_mark_all_as_read, id: 702851

    Device 1: Tap on found: Button
    # STEP: Device1 check that contact appeared in contact list mutually

    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:703: in urlopen
        httplib_response = self._make_request(
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:449: in _make_request
        six.raise_from(e, None)
    <string>:3: in raise_from
        ???
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:444: in _make_request
        httplib_response = conn.getresponse()
    /usr/lib/python3.10/http/client.py:1375: in getresponse
        response.begin()
    /usr/lib/python3.10/http/client.py:318: in begin
        version, status, reason = self._read_status()
    /usr/lib/python3.10/http/client.py:287: in _read_status
        raise RemoteDisconnected("Remote end closed connection without"
    E   http.client.RemoteDisconnected: Remote end closed connection without response
    
    During handling of the above exception, another exception occurred:
    activity_center/test_activity_center.py:133: in test_activity_center_contact_request_accept_swipe_mark_all_as_read
        self.device_2.just_fyi('Device1 check that contact appeared in contact list mutually')
    ../views/base_view.py:394: in just_fyi
        self.driver.execute_script("sauce:context=STEP: %s" % some_str)
    /home/jenkins/.local/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py:405: in execute_script
        return self.execute(command, {"script": script, "args": converted_args})["value"]
    /home/jenkins/.local/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py:343: in execute
        response = self.command_executor.execute(driver_command, params)
    /home/jenkins/.local/lib/python3.10/site-packages/selenium/webdriver/remote/remote_connection.py:291: in execute
        return self._request(command_info[0], url, body=data)
    /home/jenkins/.local/lib/python3.10/site-packages/selenium/webdriver/remote/remote_connection.py:312: in _request
        response = self._conn.request(method, url, body=body, headers=headers)
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/request.py:78: in request
        return self.request_encode_body(
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/request.py:170: in request_encode_body
        return self.urlopen(method, url, **extra_kw)
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/poolmanager.py:376: in urlopen
        response = conn.urlopen(method, u.request_uri, **kw)
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:787: in urlopen
        retries = retries.increment(
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/util/retry.py:550: in increment
        raise six.reraise(type(error), error, _stacktrace)
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/packages/six.py:769: in reraise
        raise value.with_traceback(tb)
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:703: in urlopen
        httplib_response = self._make_request(
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:449: in _make_request
        six.raise_from(e, None)
    <string>:3: in raise_from
        ???
    /home/jenkins/.local/lib/python3.10/site-packages/urllib3/connectionpool.py:444: in _make_request
        httplib_response = conn.getresponse()
    /usr/lib/python3.10/http/client.py:1375: in getresponse
        response.begin()
    /usr/lib/python3.10/http/client.py:318: in begin
        version, status, reason = self._read_status()
    /usr/lib/python3.10/http/client.py:287: in _read_status
        raise RemoteDisconnected("Remote end closed connection without"
     ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
    



    Device sessions

    Class TestActivityMultipleDevicePR:

    1. test_activity_center_reply_read_unread_delete_filter_swipe, id: 702947

    Test setup failed: activity_center/test_activity_center.py:270: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:435: in join_community
        ChatView(self.driver).chat_element_by_text("https://status.app/c/").click_on_link_inside_message_body()
    ../views/chat_view.py:193: in click_on_link_inside_message_body
        self.message_body.wait_for_visibility_of_element(30)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by xpath:`//android.view.ViewGroup[@content-desc='chat-item']//android.widget.TextView[contains(@text,'https://status.app/c/')]` is not found on the screen after wait_for_visibility_of_element
    



    2. test_navigation_jump_to, id: 702936

    Device 2: Joining community
    Device 2: Looking for a message by text: https://status.app/c/

    Test setup failed: activity_center/test_activity_center.py:270: in prepare_devices
        self.community_2.join_community()
    ../views/chat_view.py:435: in join_community
        ChatView(self.driver).chat_element_by_text("https://status.app/c/").click_on_link_inside_message_body()
    ../views/chat_view.py:193: in click_on_link_inside_message_body
        self.message_body.wait_for_visibility_of_element(30)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Text by xpath:`//android.view.ViewGroup[@content-desc='chat-item']//android.widget.TextView[contains(@text,'https://status.app/c/')]` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    Class TestGroupChatMultipleDeviceMergedNewUI:

    1. test_group_chat_pin_messages, id: 702732

    Test setup failed: critical/chats/test_group_chat.py:69: in prepare_devices
        self.chats[0] = self.homes[0].create_group_chat(user_names_to_add=[self.usernames[1], self.usernames[2]]</b>,
    ../views/home_view.py:424: in create_group_chat
        self.start_a_new_chat_bottom_sheet_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `start-a-new-chat` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    2. test_group_chat_reactions, id: 703202

    Test setup failed: critical/chats/test_group_chat.py:69: in prepare_devices
        self.chats[0] = self.homes[0].create_group_chat(user_names_to_add=[self.usernames[1], self.usernames[2]]</b>,
    ../views/home_view.py:424: in create_group_chat
        self.start_a_new_chat_bottom_sheet_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `start-a-new-chat` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    3. test_group_chat_mute_chat, id: 703495

    Test setup failed: critical/chats/test_group_chat.py:69: in prepare_devices
        self.chats[0] = self.homes[0].create_group_chat(user_names_to_add=[self.usernames[1], self.usernames[2]]</b>,
    ../views/home_view.py:424: in create_group_chat
        self.start_a_new_chat_bottom_sheet_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `start-a-new-chat` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    4. test_group_chat_join_send_text_messages_push, id: 702807

    Device 1: Tap on found: Button
    Device 1: Find Button by accessibility id: start-a-new-chat

    Test setup failed: critical/chats/test_group_chat.py:69: in prepare_devices
        self.chats[0] = self.homes[0].create_group_chat(user_names_to_add=[self.usernames[1], self.usernames[2]]</b>,
    ../views/home_view.py:424: in create_group_chat
        self.start_a_new_chat_bottom_sheet_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `start-a-new-chat` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    5. test_group_chat_send_image_save_and_share, id: 703297

    Test setup failed: critical/chats/test_group_chat.py:69: in prepare_devices
        self.chats[0] = self.homes[0].create_group_chat(user_names_to_add=[self.usernames[1], self.usernames[2]]</b>,
    ../views/home_view.py:424: in create_group_chat
        self.start_a_new_chat_bottom_sheet_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `start-a-new-chat` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    6. test_group_chat_offline_pn, id: 702808

    Test setup failed: critical/chats/test_group_chat.py:69: in prepare_devices
        self.chats[0] = self.homes[0].create_group_chat(user_names_to_add=[self.usernames[1], self.usernames[2]]</b>,
    ../views/home_view.py:424: in create_group_chat
        self.start_a_new_chat_bottom_sheet_button.click()
    ../views/base_element.py:90: in click
        self.find_element().click()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `start-a-new-chat` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Class TestDeepLinksOneDevice:

    1. test_links_open_universal_links_from_chat, id: 704613

    Device 1: Find Button by xpath: //*[@text="open community"]
    Device 1: Tap on found: Button

    critical/test_deep_and_universal_links.py:70: in test_links_open_universal_links_from_chat
        self.errors.verify_no_errors()
    base_test_case.py:191: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Community 'test_comm_enc' was not requested to join by the url https://status.app/c/GyoAAORtA48geFrtWr2mu-G5DnFaI0sgqUIIaBFX_DJ_mRbXmzoMnCJnqwI=#zQ3shQhL414wEjDJMEpgTjd14aHCiBDnk6Bq5YTWoi4b7wvnu
    E    Community 'e2e_open' was not requested to join by the url https://status.app/c/GyAAAOQbK4dMy1OMI8s2nGvJR3QRqBQqbExff0-cgmN0T-4C#zQ3shqQ4voo845RAkip2JkYTjL4dpiGnRhaNHjVDxPdEZ1xvP
    



    Device sessions

    2. test_links_deep_links, id: 702775

    Device 1: Find BrowserTab by accessibility id: browser-stack-tab
    Device 1: Tap on found: BrowserTab

    critical/test_deep_and_universal_links.py:114: in test_links_deep_links
        self.errors.verify_no_errors()
    base_test_case.py:191: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Community 'test_comm_enc' was not requested to join by the deep link status.app://c/GyoAAORtA48geFrtWr2mu-G5DnFaI0sgqUIIaBFX_DJ_mRbXmzoMnCJnqwI=#zQ3shQhL414wEjDJMEpgTjd14aHCiBDnk6Bq5YTWoi4b7wvnu
    E    Community 'e2e_open' was not requested to join by the deep link status.app://c/GyAAAOQbK4dMy1OMI8s2nGvJR3QRqBQqbExff0-cgmN0T-4C#zQ3shqQ4voo845RAkip2JkYTjL4dpiGnRhaNHjVDxPdEZ1xvP
    



    Device sessions

    Class TestActivityMultipleDevicePRTwo:

    1. test_activity_center_mentions, id: 702957

    Device 2: Tap on found: SendMessageButton
    # STEP: Checking unread indicators

    activity_center/test_activity_center.py:423: in test_activity_center_mentions
        self.home_1.notifications_unread_badge.wait_for_visibility_of_element(120)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 1: BaseElement by accessibility id:`activity-center-unread-count` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    2. test_activity_center_admin_notification_accept_swipe, id: 702958

    Device 2: Find Text by xpath: //android.view.ViewGroup[@content-desc='chat-item']//android.widget.TextView[contains(@text,'https://status.app/c/')]
    Device 2: Wait for element Button for max 120s and click when it is available

    activity_center/test_activity_center.py:469: in test_activity_center_admin_notification_accept_swipe
        self.community_2.join_community(open_community=False)
    ../views/chat_view.py:436: in join_community
        self.join_button.wait_and_click(120)
    ../views/base_element.py:96: in wait_and_click
        self.wait_for_visibility_of_element(sec)
    ../views/base_element.py:139: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 2: Button by accessibility id:`show-request-to-join-screen-button` is not found on the screen after wait_for_visibility_of_element
    



    Device sessions

    Expected to fail tests (1)

    Click to expand

    Class TestCommunityOneDeviceMerged:

    1. test_community_discovery, id: 703503

    Test is not run, e2e blocker  
    

    [[reason: [NOTRUN] Curated communities not loading, https://github.com//issues/17852]]

    Passed tests (9)

    Click to expand

    Class TestCommunityOneDeviceMerged:

    1. test_community_navigate_to_channel_when_relaunch, id: 702846
    Device sessions

    2. test_restore_multiaccount_with_waku_backup_remove_switch, id: 703133
    Device sessions

    3. test_community_mute_community_and_channel, id: 703382
    Device sessions

    4. test_community_undo_delete_message, id: 702869
    Device sessions

    5. test_community_copy_and_paste_message_in_chat_input, id: 702742
    Device sessions

    Class TestActivityCenterContactRequestMultipleDevicePR:

    1. test_add_contact_field_validation, id: 702777
    Device sessions

    2. test_activity_center_contact_request_decline, id: 702850
    Device sessions

    Class TestOneToOneChatMultipleSharedDevicesNewUiTwo:

    1. test_1_1_chat_mute_chat, id: 703496
    Device sessions

    2. test_1_1_chat_delete_via_long_press_relogin, id: 702784
    Device sessions

    @ilmotta ilmotta merged commit 505f2fe into develop Feb 8, 2024
    6 checks passed
    @ilmotta ilmotta deleted the ilmotta.18126/relevant-tokens branch February 8, 2024 14:17
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    community community-account-selection https://www.notion.so/Ledger-Drops-b0df9c843f904bb380133375bae3faa7 feature feature requests
    Projects
    Archived in project
    Archived in project
    Development

    Successfully merging this pull request may close these issues.

    Communities: Show relevant tokens in Addresses for Permissions screen
    6 participants